---
title: SAIF.Services.Appworx operations and processes
summary: Business and technical operations supported by this library.
status: draft
owner: <owner>
last_reviewed: 2026-08-25
library: SAIF.Services.Appworx
reference_type: package
---

# SAIF.Services.Appworx operations and processes

This page is the operation catalog and cross-operation hub for this library. Each operation's detailed, step-by-step logic lives in its own page under `operations/`.

## Operation catalog

| Operation | Intent | Trigger | Inputs | Outputs | Rules | Tables | SQL |
| --- | --- | --- | --- | --- | --- | --- | --- |
| [Submit Appworx batch job (instance)](operations/submit-appworx-batch-job.md) | Submit a configured Appworx batch-job request to Oracle | Caller calls `SubmitBatchJob()` on a constructed `clsRequestAppworxJob` | `ModuleName`, `Requestor`, `Printer`, `Arg1`–`Arg20` | Stored-procedure submission (fire-and-forget); `ApplicationException` on failure | [BR-APX-001](business-rules.md#br-apx-001-optional-arguments-omitted-when-empty), [BR-APX-002](business-rules.md#br-apx-002-submission-failures-are-wrapped-and-rethrown) | `JOB_QUEUE` | [SQL-APPWORX-001](sql/SQL-APPWORX-001-submit-appworx-job.md) |
| [Reset job arguments](operations/reset-job-arguments.md) | Clear all 20 argument slots before reuse | Constructor, or explicit call to `InitArgs()` | None | `Arg1`–`Arg20` reset to empty | None | N/A | N/A |
| [Submit Appworx batch job (shared overload)](operations/submit-appworx-batch-job-shared.md) | Convenience one-call wrapper to construct, populate, and submit an Appworx job | Caller invokes the shared `SubmitBatchJob(...)` overload | `inDPI`, `inModule`, optional `inRequestor`/`inPrinter`/`inArg1`–`inArg20`/`inUseWCISDEV1AppworxForAllDevEnv` | Delegates to the instance `SubmitBatchJob()` operation | [BR-APX-003](business-rules.md#br-apx-003-non-production-appworx-target-override), [BR-APX-004](business-rules.md#br-apx-004-unspecified-arguments-left-unset-in-shared-overload) | `JOB_QUEUE` | [SQL-APPWORX-001](sql/SQL-APPWORX-001-submit-appworx-job.md) |

## Process flow diagram
The following diagram visualizes the primary operational flow from caller through the environment-override decision to the Appworx stored procedure.

```mermaid
flowchart TD
    Start([Caller invokes shared SubmitBatchJob]) --> Decision{inUseWCISDEV1AppworxForAllDevEnv = True?}
    Decision -->|Yes, Prod env| Prod[Use clsMSOracleDataLayer PRADT/WCISPROD]
    Decision -->|Yes, non-Prod env| Dev[Use clsMSOracleDataLayer PRADT/WCISDEV1]
    Decision -->|No| CallerDPI[Use caller-supplied IDataPortalInfo]
    Prod --> Construct[Construct clsRequestAppworxJob and InitArgs]
    Dev --> Construct
    CallerDPI --> Construct
    Construct --> SetProps[Set ModuleName, Requestor, Printer, Arg1..Arg20]
    SetProps --> Instance[Instance SubmitBatchJob executes stored procedure]
    Instance --> Result{Exception?}
    Result -->|Yes| Wrap([Throw ApplicationException])
    Result -->|No| Done([Job submitted])
```

## Database interactions

| Operation | SQL | Tables | Type |
| --- | --- | --- | --- |
| [Submit Appworx batch job (instance)](operations/submit-appworx-batch-job.md) | [SQL-APPWORX-001](sql/SQL-APPWORX-001-submit-appworx-job.md) | `JOB_QUEUE` | Write |
| [Submit Appworx batch job (shared overload)](operations/submit-appworx-batch-job-shared.md) | [SQL-APPWORX-001](sql/SQL-APPWORX-001-submit-appworx-job.md) | `JOB_QUEUE` | Write |

## Failure and edge-case behavior
- Any exception from `DPI.ProcessPortalRequest` in the instance `SubmitBatchJob()` is caught and rethrown as `ApplicationException` ([BR-APX-002](business-rules.md#br-apx-002-submission-failures-are-wrapped-and-rethrown)).
- Argument slots left empty/`Nothing` by the caller are never sent to the stored procedure ([BR-APX-001](business-rules.md#br-apx-001-optional-arguments-omitted-when-empty), [BR-APX-004](business-rules.md#br-apx-004-unspecified-arguments-left-unset-in-shared-overload)).

## Stored procedure operations

The retrieved Oracle source for `WCIS_DBA.submit_appworx_job` exposes the following internal procedure operations.

| Operation | Description | Source | Link |
| --- | --- | --- | --- |
| Allocate next job ID from `so_max_jobid` | Select `SO_MAX_JOBID.NEXTVAL` into `v_jobid` before the queue insert. | `WCIS_DBA.submit_appworx_job` | [Details](procedures/submit-appworx-job.md#allocate-next-job-id-from-so_max_jobid) |
| Insert `JOB_QUEUE` request row | Insert one `JOB_QUEUE` row with `MODULE`, `REQUESTOR`, fixed `MASTER_JOB_NUMBER = -1`, generated `JOBID`, and `ARG_1` through `ARG_20`; `inprinter` is not referenced in the retrieved body. | `WCIS_DBA.submit_appworx_job` | [Details](procedures/submit-appworx-job.md#insert-job_queue-request-row) |
| Handle exception outcomes | Swallow `NO_DATA_FOUND` and re-raise every other exception. | `WCIS_DBA.submit_appworx_job` | [Details](procedures/submit-appworx-job.md#handle-exception-outcomes) |

## Related documentation
- [Index](index.md)
- [Overview](overview.md)
- [Architecture](architecture.md)
- [Dependencies](dependencies.md)
- [Business rules](business-rules.md)
- [Database tables](database-tables.md)
- [Configuration](configuration.md)
- [SQL catalog](sql/index.md)
- [Stored procedures](procedures/index.md)
- [API reference](api/index.md)

## Sources
- `SAIF.Services.Appworx\clsRequestAppworxJob.vb`
- Oracle retrieval: `C:\Users\chrfre\AppData\Local\Temp\oracle-sources\submit_appworx_job.json`
